package com.demo.service.impl;

import com.demo.dao.BuyGoodDAO;
import com.demo.dao.impl.BuyGoodDAOImpl;
import com.demo.service.BuyGoodService;
import com.demo.vo.BuyGood;

import java.io.Serializable;
import java.util.Map;

/**
 * 商品模块的Service层（业务层）的具体实现类，对GoodService接口中定义的抽象方法作出具体的功能实现
 */
public class BuyGoodServiceImpl implements BuyGoodService {
    //@Override
    public void add(BuyGood vo) {
        BuyGoodDAO buygoodDAO = new BuyGoodDAOImpl();
        buygoodDAO.add(vo);
    }

    //@Override
    public BuyGood get(Serializable id) {
        BuyGoodDAO buygoodDAO = new BuyGoodDAOImpl();
        return buygoodDAO.get(id);
    }

    //@Override
    public Map<String, Object> list(Map<String, Object> params) {
        BuyGoodDAO buygoodDAO = new BuyGoodDAOImpl();
        return buygoodDAO.list(params);
    }
}
